Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Optimize translation prompts #126

Merged

Conversation

MilesHan
Copy link
Contributor

πŸ’» ε˜ζ›΄η±»εž‹ | Change Type

  • ✨ feat
  • πŸ› fix
  • ♻️ refactor
  • πŸ’„ style
  • πŸ”¨ chore
  • πŸ“ docs

πŸ”€ ε˜ζ›΄θ―΄ζ˜Ž | Description of Change

  1. Optimize the JSON translation prompt to maintain the JSON format of the translation results
  2. Updated JSON example to add JSON array

πŸ“ θ‘₯充俑息 | Additional Information

#100

I reproduced the issue above. For example, when I use the original prompt to translate the example en_US.json I gave, it will appear stably ... is not valid JSON
image

After add Do not include any additional text or explanations outside the JSON object.Start directly with a left brace and end with a right brace.,I tested several complex nested JSON files and all of them were translated stably.

@kiwiflydream
Copy link

ζ„Ÿθ°’οΌŒζˆ‘ζŠŠδ½ ηš„ζη€Ίθ―­ζ”Ύεˆ° reference εŽοΌŒε°±ζžε°‘ε‡ΊηŽ°η±»δΌΌηš„ι”™θ――δΊ†γ€‚

@canisminor1990 canisminor1990 merged commit 12520fe into lobehub:master Sep 13, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants